package joodle.ui;

import static joodle.si.ResourceManager.makeIcon;
import static joodle.si.ResourceManager.message;

import java.awt.Desktop;
import java.awt.event.ActionEvent;
import java.awt.event.KeyEvent;
import java.net.URI;

import javax.swing.AbstractAction;

@SuppressWarnings("serial")
public class HelpAction extends AbstractAction {
	public HelpAction() {
		super(message("UserGuide"), makeIcon("help"));
		putValue(MNEMONIC_KEY, KeyEvent.VK_H);
	}

	@Override
	public void actionPerformed(ActionEvent e) {
		try {
			Desktop.getDesktop().browse(new URI(JoodleFrame.GUIDE_URL));
		} catch (Exception ure) {
		}
	}
};